<div class="productPromotions index">
    <h2><?php echo __('Product Promotions'); ?></h2>
    <table cellpadding="0" cellspacing="0">
        <tr>
    <!--			<th><?php // echo $this->Paginator->sort('id');    ?></th>-->
            <th><?php echo $this->Paginator->sort('promotion_id', 'Promocion') ?></th>
            <th><?php echo $this->Paginator->sort('product_id', 'Producto'); ?></th>
            <th><?php echo $this->Paginator->sort('quantity', 'Cantidad'); ?></th>
            <th class="actions"><?php echo __('Opciones'); ?></th>
        </tr>
        <?php foreach ($productPromotions as $productPromotion): ?>
            <tr>
        <!--		<td><?php // echo h($productPromotion['ProductPromotion']['id']);    ?>&nbsp;</td>-->
                <td>
                    <?php echo $this->Html->link($productPromotion['Promotion']['name'], array('controller' => 'promotions', 'action' => 'view', $productPromotion['Promotion']['id'])); ?>
                </td>
                <td>
                    <?php echo $this->Html->link($productPromotion['Product']['name'], array('controller' => 'products', 'action' => 'view', $productPromotion['Product']['id'])); ?>
                </td>

                <td><?php echo h($productPromotion['ProductPromotion']['quantity']); ?>&nbsp;</td>
                <td class="actions">
                    <?php echo $this->Html->link(__('View'), array('action' => 'view', $productPromotion['ProductPromotion']['id'])); ?>
                    <?php echo $this->Html->link(__('Edit'), array('action' => 'edit', $productPromotion['ProductPromotion']['id'])); ?>
                    <?php echo $this->Form->postLink(__('Delete'), array('action' => 'delete', $productPromotion['ProductPromotion']['id']), null, __('Are you sure you want to delete # %s?', $productPromotion['ProductPromotion']['id'])); ?>
                </td>
            </tr>
        <?php endforeach; ?>
    </table>

    <?php echo $this->element('footer/paginator') ?>

</div>
<div class="actions">
    <h3><?php echo __('Opciones'); ?></h3>
    <ul>
        <li><?php echo $this->Html->link(__('Productos'), array('controller' => 'products', 'action' => 'index')); ?> </li>
        <li><?php echo $this->Html->link(__('Agregar Producto'), array('controller' => 'ProductPromotions', 'action' => 'add')); ?> </li>
        <li><?php echo $this->Html->link(__('Nuevo Producto'), array('controller' => 'products', 'action' => 'add')); ?> </li>
        <li><?php echo $this->Html->link(__('Promociones'), array('controller' => 'promotions', 'action' => 'index')); ?> </li>
        <li><?php echo $this->Html->link(__('Crear Promocion'), array('controller' => 'promotions', 'action' => 'add')); ?> </li>
    </ul>
</div>
